package org.example.mq.mqclient;

import java.io.IOException;

/**
 * Created with IntelliJ IDEA.
 * Description:做渐进主义的改良派,不做完没注意的速成派
 * User: XALEXC
 * Date: 2025-06-25
 * Time: 16:32
 */
public class ConnectionFactory {
    // broker server的ip地址和端口号
    private String host;
    private int port;

    public Connection newConnection() throws IOException {
        Connection connection=new Connection(host,port);
        return connection;
    }
    public String getHost() {
        return host;
    }

    public void setHost(String host) {
        this.host = host;
    }

    public int getPort() {
        return port;
    }

    public void setPort(int port) {
        this.port = port;
    }
}
